package com.mytx.mapper;

import com.mytx.pojo.MytxConfigEntiy;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * 配置文件信息表的相关操作
 */
public interface MytxConfigMapper {

    /**
     * 查询出所有的配置文件信息
     * @return
     */
    @Select("SELECT id,config_name as configName,config_value as configValue,type,updated,created FROM mytx_config")
    List<MytxConfigEntiy> findByAll();

    /**
     * 查询指定的配置文件信息
     * @param configName
     * @return
     */
    @Select("SELECT id,config_name as configName,config_value as configValue,type,updated,created FROM mytx_config WHERE config_name = #{configName}")
    MytxConfigEntiy findByConfigName(@Param("configName") String configName);

}
